Operating System


Q111.

In a file allocation system, which of the following allocation schemes(s) can be used if no external fragmentation is allowed? I. Contiguous II. Linked III. Indexed
GateOverflow

Q112.

Consider two files systems A and B , that use contiguous allocation and linked allocation, respectively. A file of size 100 blocks is already stored in A and also in B. Now, consider inserting a new block in the middle of the file (between 50^{th} \text{ and }51^{st} block), whose data is already available in the memory. Assume that there are enough free blocks at the end of the file and that the file control blocks are already in memory. Let the number of disk accesses required to insert a block in the middle of the file in A and B are n_A and n_B, respectively, then the value of n_A+n_B is
GateOverflow

Q113.

Consider a computer system with 57-bit virtual addressing using multi-level tree-structured page tables with L levels for virtual to physical address translation. The page size is 4 KB (1 KB = 1024 B) and a page table entry at any of the levels occupies 8 bytes. The value of L is ______.
GateOverflow

Q114.

Consider the following two-dimensional array D in the C programming language, which is stored in row-major order: int D[128][128]; Demand paging is used for allocating memory and each physical page frame holds 512 elements of the array D. The Least Recently Used (LRU) page-replacement policy is used by the operating system. A total of 30 physical page frames are allocated to a process which executes the following code snippet: for (int i = 0; i < 128; i++) for (int j = 0; j < 128; j++) D[j][i] *= 10; The number of page faults generated during the execution of this code snippet is _____.
GateOverflow

Q115.

Consider a demand paging system with four page frames (initially empty) and LRU page replacement policy. For the following page reference string 7, 2, 7, 3, 2, 5, 3, 4, 6, 7, 7,1, 5, 6,1 the page fault rate, defined as the ratio of number of page faults to the number of memory accesses (rounded off to one decimal place) is
GateOverflow

Q116.

Consider a three-level page table to translate a 39-bit virtual address to a physical address as shown below: The page size is 4 KB = (1KB =2^{10} bytes) and page table entry size at every level is 8 bytes. A process P is currently using 2 GB (1 GB =2^{30} bytes) virtual memory which os mapped to 2 GB of physical memory. The minimum amount of memory required for the page table of P across all levels is _________ KB
GateOverflow

Q117.

Consider the following page reference string.1 2 3 4 2 1 5 6 2 1 2 3 7 6 3 2 1 2 3 6 What are the minimum number of frames required to get a single page fault for the above sequence assuming LRU replacement strategy?
GateOverflow

Q118.

In the context of operating systems, which of the following statements is/are correct with respect to paging?[MSQ]
GateOverflow

Q119.

Which one of the following statements is FALSE?
GateOverflow

Q120.

What is compaction refers to
GateOverflow